package com.byxy.service.impl;

import java.util.List;

import javax.annotation.Resource;
import javax.transaction.Transactional;

import org.springframework.stereotype.Repository;
import org.springframework.stereotype.Service;

import com.byxy.dao.UserDao;
import com.byxy.entity.User;
import com.byxy.service.UserService;
@Transactional
@Service
public class UserServiceImpl implements UserService {
	@Resource
	private UserDao userDao;

	@Override
	public void add(User s) {
		userDao.add(s);
		
	}

	@Override
	public void delet(User s) {
		userDao.delete(s);
		
	}

	@Override
	public void update(User s) {
		userDao.update(s);
		
	}

	@Override
	public List<User> find() {
		
		return userDao.find();
	}

	@Override
	public List<User> find(int pos, int rows) {
		
		return userDao.find(pos, rows);
	}

	@Override
	public User get(Integer id) {
		
		return userDao.get(id);
	}

	@Override
	public long count() {
		
		return userDao.count();
	}
	
}
